\(\int \frac {\cosh (a+\frac {b}{x})}{x^2} \, dx\) [27]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 12, antiderivative size = 13 \[ \int \frac {\cosh \left (a+\frac {b}{x}\right )}{x^2} \, dx=-\frac {\sinh \left (a+\frac {b}{x}\right )}{b} \]

[Out]

-sinh(a+b/x)/b

Rubi [A] (verified)

Time = 0.01 (sec) , antiderivative size = 13, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {5429, 2717} \[ \int \frac {\cosh \left (a+\frac {b}{x}\right )}{x^2} \, dx=-\frac {\sinh \left (a+\frac {b}{x}\right )}{b} \]

[In]

Int[Cosh[a + b/x]/x^2,x]

[Out]

-(Sinh[a + b/x]/b)

Rule 2717

Int[sin[Pi/2 + (c_.) + (d_.)*(x_)], x_Symbol] :> Simp[Sin[c + d*x]/d, x] /; FreeQ[{c, d}, x]

Rule 5429

Int[((a_.) + Cosh[(c_.) + (d_.)*(x_)^(n_)]*(b_.))^(p_.)*(x_)^(m_.), x_Symbol] :> Dist[1/n, Subst[Int[x^(Simpli
fy[(m + 1)/n] - 1)*(a + b*Cosh[c + d*x])^p, x], x, x^n], x] /; FreeQ[{a, b, c, d, m, n, p}, x] && IntegerQ[Sim
plify[(m + 1)/n]] && (EqQ[p, 1] || EqQ[m, n - 1] || (IntegerQ[p] && GtQ[Simplify[(m + 1)/n], 0]))

Rubi steps \begin{align*} \text {integral}& = -\text {Subst}\left (\int \cosh (a+b x) \, dx,x,\frac {1}{x}\right ) \\ & = -\frac {\sinh \left (a+\frac {b}{x}\right )}{b} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.00 (sec) , antiderivative size = 13, normalized size of antiderivative = 1.00 \[ \int \frac {\cosh \left (a+\frac {b}{x}\right )}{x^2} \, dx=-\frac {\sinh \left (a+\frac {b}{x}\right )}{b} \]

[In]

Integrate[Cosh[a + b/x]/x^2,x]

[Out]

-(Sinh[a + b/x]/b)

Maple [A] (verified)

Time = 0.05 (sec) , antiderivative size = 14, normalized size of antiderivative = 1.08

method result size
derivativedivides \(-\frac {\sinh \left (a +\frac {b}{x}\right )}{b}\) \(14\)
default \(-\frac {\sinh \left (a +\frac {b}{x}\right )}{b}\) \(14\)
parallelrisch \(-\frac {\sinh \left (\frac {a x +b}{x}\right )}{b}\) \(16\)
risch \(-\frac {{\mathrm e}^{\frac {a x +b}{x}}}{2 b}+\frac {{\mathrm e}^{-\frac {a x +b}{x}}}{2 b}\) \(33\)
meijerg \(-\frac {\cosh \left (a \right ) \sinh \left (\frac {b}{x}\right )}{b}+\frac {\sqrt {\pi }\, \sinh \left (a \right ) \left (\frac {1}{\sqrt {\pi }}-\frac {\cosh \left (\frac {b}{x}\right )}{\sqrt {\pi }}\right )}{b}\) \(39\)

[In]

int(cosh(a+b/x)/x^2,x,method=_RETURNVERBOSE)

[Out]

-sinh(a+b/x)/b

Fricas [A] (verification not implemented)

none

Time = 0.24 (sec) , antiderivative size = 15, normalized size of antiderivative = 1.15 \[ \int \frac {\cosh \left (a+\frac {b}{x}\right )}{x^2} \, dx=-\frac {\sinh \left (\frac {a x + b}{x}\right )}{b} \]

[In]

integrate(cosh(a+b/x)/x^2,x, algorithm="fricas")

[Out]

-sinh((a*x + b)/x)/b

Sympy [A] (verification not implemented)

Time = 0.26 (sec) , antiderivative size = 15, normalized size of antiderivative = 1.15 \[ \int \frac {\cosh \left (a+\frac {b}{x}\right )}{x^2} \, dx=\begin {cases} - \frac {\sinh {\left (a + \frac {b}{x} \right )}}{b} & \text {for}\: b \neq 0 \\- \frac {\cosh {\left (a \right )}}{x} & \text {otherwise} \end {cases} \]

[In]

integrate(cosh(a+b/x)/x**2,x)

[Out]

Piecewise((-sinh(a + b/x)/b, Ne(b, 0)), (-cosh(a)/x, True))

Maxima [A] (verification not implemented)

none

Time = 0.18 (sec) , antiderivative size = 13, normalized size of antiderivative = 1.00 \[ \int \frac {\cosh \left (a+\frac {b}{x}\right )}{x^2} \, dx=-\frac {\sinh \left (a + \frac {b}{x}\right )}{b} \]

[In]

integrate(cosh(a+b/x)/x^2,x, algorithm="maxima")

[Out]

-sinh(a + b/x)/b

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 29 vs. \(2 (13) = 26\).

Time = 0.30 (sec) , antiderivative size = 29, normalized size of antiderivative = 2.23 \[ \int \frac {\cosh \left (a+\frac {b}{x}\right )}{x^2} \, dx=-\frac {e^{\left (\frac {a x + b}{x}\right )} - e^{\left (-\frac {a x + b}{x}\right )}}{2 \, b} \]

[In]

integrate(cosh(a+b/x)/x^2,x, algorithm="giac")

[Out]

-1/2*(e^((a*x + b)/x) - e^(-(a*x + b)/x))/b

Mupad [B] (verification not implemented)

Time = 1.55 (sec) , antiderivative size = 13, normalized size of antiderivative = 1.00 \[ \int \frac {\cosh \left (a+\frac {b}{x}\right )}{x^2} \, dx=-\frac {\mathrm {sinh}\left (a+\frac {b}{x}\right )}{b} \]

[In]

int(cosh(a + b/x)/x^2,x)

[Out]

-sinh(a + b/x)/b